package com.kgis.kp.common.vo;

import java.io.Serializable;

/**
 * 
 * @author zhxiaomiao
 * 
 */
public class Entry<K, V> implements Serializable {

	/**
	 *
	 */
	private static final long serialVersionUID = -8734957183278577776L;

	private K key;

	private V value;

	public Entry() {

	}

	public Entry(K key, V value) {
		this.setKey(key);
		this.setValue(value);
	}

	public String toString() {
		StringBuilder sb = new StringBuilder();
		sb.append("{key=" + key);
		sb.append(",value=" + value);
		sb.append("}");
		// key.class=" + ReflectionUtil.getGenericType(this.getClass()));
		// sb.append(", value.class=" +
		// ReflectionUtil.getGenericType(this.getClass(), 1));
		return sb.toString();
	}

	/**
	 * @return the key
	 */
	public K getKey() {
		return key;
	}

	/**
	 * @param key
	 *            the key to set
	 */
	public void setKey(K key) {
		this.key = key;
	}

	/**
	 * @return the value
	 */
	public V getValue() {
		return value;
	}

	/**
	 * @param value
	 *            the value to set
	 */
	public void setValue(V value) {
		this.value = value;
	}

}
